#include <iostream>
using namespace std;
int main() {
    int T, n, d;
    cin >> T;
    while(T--){
        cin >> n >> d;
        int x = (n-1)/2;
        int tmp = (d+x)/(x+1);
        if(x + tmp < n || x + tmp == n) cout << "YES\n";
        else{
            x++;
            tmp = (d+x)/(x+1);
            if (x + tmp < n ||  x + tmp == n) cout << "YES\n";
            else cout << "NO\n";
        }
    }
    return 0;
}
